Prv8 Shell
Server : Apache
System : Linux server.mata-lashes.com 3.10.0-1160.90.1.el7.x86_64 #1 SMP Thu May 4 15:21:22 UTC 2023 x86_64
User : matalashes ( 1004)
PHP Version : 8.1.29
Disable Function : NONE
Directory :  /home/matalashes/.trash/app/Views/admin/pages/custom/report/reportpembelian/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /home/matalashes/.trash/app/Views/admin/pages/custom/report/reportpembelian/reportpembelian.bak
<?= $this->extend('admin/layout/report/admin_report') ?>
<?= $this->section('content') ?>
    <!-- ============================================================== -->
    <!-- Page Content -->
    <!-- ============================================================== -->

    <!-- ============================================================== -->
    <!-- Different data widgets -->
    <!-- ============================================================== -->
<?php
$session = service('session');
echo form_content_table_tag_open('table', 'table align-middle table-row-dashed fs-6 gy-5', '', $session->get('trash')) ?>
    <thead>
    <tr class="text-start text-muted fw-bolder fs-7 text-uppercase gs-0">
        <th hidden>ID</th>
        <th>Tgl</th>
        <th>Barang</th>
        <th>Jml Pembelian</th>
        <th>Harga Satuan</th>
        <th>Total</th>
        <th class="text-end">#</th>
    </tr>
    </thead>
    <tbody class="text-gray-600 fw-bold">
    <?php foreach ($_pembelian as $d) { 
        $created_at = date("d M Y H:i", strtotime($d->created_at ?? ''));
    ?>
            <?php
            $json = json_decode($d->pf_item);
            foreach($json as $j){
                $o = $j->item;
                $v = $j->qty;
                $p = $j->price;

                $barang = new  \App\Models\MasterBarang();
                $_barang = $barang->find($o);
                ?>
                <tr>
                    <td hidden><?= $d->pf_id ?></td> 
                    <td><?= $created_at ?></td>
                    <td><?= '['.$_barang->mb_kode.']'.$_barang->mb_merk.' - '.$_barang->mb_name ?></td>
                    <td><?= $v ?></td>
                    <td><?= 'Rp '.number_format($p ?? 0, 0, ',', '.') ?></td>
                    <td><?= 'Rp '.number_format($v*$p ?? 0, 0, ',', '.') ?></td>
                    <td>&nbsp;</td>
                </tr>
                <?php
                if(!empty($created_at)){
                    $created_at = '';
                }
            }
        ?>
        <?php
    }
    ?>
    </tbody>
<?= form_content_table_tag_close(); ?>
    <!-- End Page Content -->
    <!-- ============================================================== -->
<?= $this->endSection('content') ?>

haha - 2025